package com.wwwarehouse.resource_center.eventbus_event;

/**
 * @author Joseph on 2017/9/4.
 *         <p/>
 */

public class RulesEvent<T> {
    public  static final int RULE_NAME = 1;           //规则名称
    public  static final int RULE_BUSINESSIDS = 2;    //应用对象
    public  static final int RULE_TASK = 3;           //任务
    public  static final int RULE_OPERATOR = 4;       //操作者
    public  static final int RULE_ALLOCATETACTICS = 5;//分配方式
    public  static final int RULE_REFRESH = 6;//编辑规则成功刷新
    public  static final int RULE_SELECT_STOCKS = 7;//选择应用对象
    public  static final int RULE_SELECT_TASK = 8;//选择任务
    public  static final int RULE_DRAWER_LINKAGE = 9;//信息卡筛选
    private int code;
    private T data;
    private String msg;

    public RulesEvent(int code) {
        this.code = code;
    }

    public RulesEvent(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public RulesEvent(int code, T data) {
        this.code = code;
        this.data = data;
    }

    public RulesEvent(int code, T data, String msg) {
        this.code = code;
        this.data = data;
        this.msg = msg;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public T getData() {
        return data;
    }

    public void setData(T data) {
        this.data = data;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }
}
